﻿using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;

namespace ProjectResistance
{
    internal class ToleranceLabelAttribute : Attribute
    {
        public string Label { get; set; }

        public ToleranceLabelAttribute(string label)
        {
            Label = label;
        }
    }

    internal enum ToleranceValues
    {
        [ToleranceLabel("1%")]
        OnePercent = BandColor.Brown,           // brown    +/- 1%
        [ToleranceLabel("2%")]
        TwoPercent = BandColor.Red,             // red      +/- 2%
        [ToleranceLabel("0.5%")]
        PointFivePercent = BandColor.Green,     // green    +/- 0.5%
        [ToleranceLabel("0.25%")]
        PointTwoFivePercent = BandColor.Blue,  // blue     +/- 0.25%
        [ToleranceLabel("0.1%")]
        PointOnePercent = BandColor.Purple,     // violet   +/- 0.1%
        [ToleranceLabel("0.05%")]
        PointZeroFivePercent = BandColor.Grey,  // grey     +/- 0.05%
        [ToleranceLabel("5%")]
        FivePercent = BandColor.Gold,           // gold     +/- 5%
        [ToleranceLabel("10%")]
        TenPercent = BandColor.Silver,          // silver   +/- 10%
        [ToleranceLabel("20%")]
        TwentyPercent = BandColor.None          // none     +/- 20%
    }
}
